home *** CD-ROM | disk | FTP | other *** search
- /*
- File: ToolUtils.h
-
- Copyright: © 1984-1993 by Apple Computer, Inc., all rights reserved.
-
- WARNING
- This file was auto generated by the interfacer tool. Modifications
- must be made to the master file.
-
- */
-
- #ifndef __TOOLUTILS__
- #define __TOOLUTILS__
-
- #ifndef __TYPES__
- #include <Types.h>
- /* #include <ConditionalMacros.h> */
- /* #include <MixedMode.h> */
- /* #include <Traps.h> */
- #endif
-
- #ifndef __QUICKDRAW__
- #include <Quickdraw.h>
- /* #include <QuickdrawText.h> */
- /* #include <IntlResources.h> */
- #endif
-
- #ifndef __TEXTUTILS__
- #include <TextUtils.h>
- /* #include <Script.h> */
- /* #include <Events.h> */
- /* #include <OSUtils.h> */
- #endif
-
- #ifndef __FIXMATH__
- #include <FixMath.h>
- #endif
-
- enum {
- sysPatListID = 0,
- iBeamCursor = 1,
- crossCursor = 2,
- plusCursor = 3,
- watchCursor = 4
- };
-
- #if defined(powerc) || defined (__powerc)
- #pragma options align=mac68k
- #endif
- struct Int64Bit {
- long hiLong;
- unsigned long loLong;
- };
- #if defined(powerc) || defined(__powerc)
- #pragma options align=reset
- #endif
-
- typedef struct Int64Bit Int64Bit;
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- extern pascal Fixed FixRatio(short numer, short denom)
- ONEWORDINLINE(0xA869);
- extern pascal Fixed FixMul(Fixed a, Fixed b)
- ONEWORDINLINE(0xA868);
- extern pascal short FixRound(Fixed x)
- ONEWORDINLINE(0xA86C);
- extern pascal void PackBits(Ptr *srcPtr, Ptr *dstPtr, short srcBytes)
- ONEWORDINLINE(0xA8CF);
- extern pascal void UnpackBits(Ptr *srcPtr, Ptr *dstPtr, short dstBytes)
- ONEWORDINLINE(0xA8D0);
- extern pascal Boolean BitTst(const void *bytePtr, long bitNum)
- ONEWORDINLINE(0xA85D);
- extern pascal void BitSet(void *bytePtr, long bitNum)
- ONEWORDINLINE(0xA85E);
- extern pascal void BitClr(void *bytePtr, long bitNum)
- ONEWORDINLINE(0xA85F);
- extern pascal long BitAnd(long value1, long value2)
- ONEWORDINLINE(0xA858);
- extern pascal long BitOr(long value1, long value2)
- ONEWORDINLINE(0xA85B);
- extern pascal long BitXor(long value1, long value2)
- ONEWORDINLINE(0xA859);
- extern pascal long BitNot(long value)
- ONEWORDINLINE(0xA85A);
- extern pascal long BitShift(long value, short count)
- ONEWORDINLINE(0xA85C);
- #if !defined(powerc) && !defined(__powerc)
- extern pascal void LongMul(long a, long b, Int64Bit *result)
- ONEWORDINLINE(0xA867);
- #else
- #define LongMul(a, b, result) ((void) WideMultiply((a), (b), (wide*)(result)))
-
- #endif
-
- extern pascal Handle GetIcon(short iconID)
- ONEWORDINLINE(0xA9BB);
- extern pascal void PlotIcon(const Rect *theRect, Handle theIcon)
- ONEWORDINLINE(0xA94B);
- extern pascal PatHandle GetPattern(short patternID)
- ONEWORDINLINE(0xA9B8);
- extern pascal CursHandle GetCursor(short cursorID)
- ONEWORDINLINE(0xA9B9);
- extern pascal PicHandle GetPicture(short pictureID)
- ONEWORDINLINE(0xA9BC);
- extern pascal Fixed SlopeFromAngle(short angle)
- ONEWORDINLINE(0xA8BC);
- extern pascal short AngleFromSlope(Fixed slope)
- ONEWORDINLINE(0xA8C4);
- extern pascal long DeltaPoint(Point ptA, Point ptB)
- ONEWORDINLINE(0xA94F);
- extern pascal void ShieldCursor(const Rect *shieldRect, Point offsetPt)
- ONEWORDINLINE(0xA855);
- extern pascal void ScreenRes(short *scrnHRes, short *scrnVRes)
- SIXWORDINLINE(0x225F, 0x32B8, 0x0102, 0x225F, 0x32B8, 0x0104);
- extern pascal void GetIndPattern(Pattern *thePat, short patternListID, short index);
- extern void shieldcursor(const Rect *shieldRect, Point *offsetPt);
- extern long deltapoint(Point *ptA, Point *ptB);
-
- /* Obsolete Math Routines */
-
- #if false
- extern pascal short HiWord(long x)
- ONEWORDINLINE(0xA86A);
- #endif
-
- #define HiWord(x) ((short)((long)(x) >> 16))
-
- #if false
- extern pascal short LoWord(long x)
- ONEWORDINLINE(0xA86B);
- #endif
-
- #define LoWord(x) ((short)(x))
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif
-
-